Optimal. Leaf size=102 \[ \frac {2 a^{3/2} \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}+\frac {2 a \cot (e+f x) \sqrt {a+a \sec (e+f x)}}{c^2 f}-\frac {4 \cot ^3(e+f x) (a+a \sec (e+f x))^{3/2}}{3 c^2 f} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.11, antiderivative size = 102, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 5, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.179, Rules used = {3989, 3972,
464, 331, 209} \begin {gather*} \frac {2 a^{3/2} \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a \sec (e+f x)+a}}\right )}{c^2 f}-\frac {4 \cot ^3(e+f x) (a \sec (e+f x)+a)^{3/2}}{3 c^2 f}+\frac {2 a \cot (e+f x) \sqrt {a \sec (e+f x)+a}}{c^2 f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 209
Rule 331
Rule 464
Rule 3972
Rule 3989
Rubi steps
\begin {align*} \int \frac {(a+a \sec (e+f x))^{3/2}}{(c-c \sec (e+f x))^2} \, dx &=\frac {\int \cot ^4(e+f x) (a+a \sec (e+f x))^{7/2} \, dx}{a^2 c^2}\\ &=-\frac {2 \text {Subst}\left (\int \frac {2+a x^2}{x^4 \left (1+a x^2\right )} \, dx,x,-\frac {\tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}\\ &=-\frac {4 \cot ^3(e+f x) (a+a \sec (e+f x))^{3/2}}{3 c^2 f}+\frac {(2 a) \text {Subst}\left (\int \frac {1}{x^2 \left (1+a x^2\right )} \, dx,x,-\frac {\tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}\\ &=\frac {2 a \cot (e+f x) \sqrt {a+a \sec (e+f x)}}{c^2 f}-\frac {4 \cot ^3(e+f x) (a+a \sec (e+f x))^{3/2}}{3 c^2 f}-\frac {\left (2 a^2\right ) \text {Subst}\left (\int \frac {1}{1+a x^2} \, dx,x,-\frac {\tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}\\ &=\frac {2 a^{3/2} \tan ^{-1}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}+\frac {2 a \cot (e+f x) \sqrt {a+a \sec (e+f x)}}{c^2 f}-\frac {4 \cot ^3(e+f x) (a+a \sec (e+f x))^{3/2}}{3 c^2 f}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.68, size = 113, normalized size = 1.11 \begin {gather*} -\frac {2 a \sqrt {\cos (e+f x)} \sqrt {a (1+\sec (e+f x))} \left (\sqrt {\cos (e+f x)} (-3+5 \cos (e+f x))-6 \sqrt {2} \text {ArcSin}\left (\sqrt {2} \sin \left (\frac {1}{2} (e+f x)\right )\right ) \sin ^3\left (\frac {1}{2} (e+f x)\right )\right ) \tan \left (\frac {1}{2} (e+f x)\right )}{3 c^2 f (-1+\cos (e+f x))^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(214\) vs.
\(2(90)=180\).
time = 0.21, size = 215, normalized size = 2.11
method | result | size |
default | \(-\frac {\sqrt {\frac {a \left (\cos \left (f x +e \right )+1\right )}{\cos \left (f x +e \right )}}\, \left (3 \sin \left (f x +e \right ) \cos \left (f x +e \right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) \sqrt {2}-3 \sqrt {2}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right )-10 \left (\cos ^{2}\left (f x +e \right )\right )+6 \cos \left (f x +e \right )\right ) a}{3 c^{2} f \sin \left (f x +e \right ) \left (-1+\cos \left (f x +e \right )\right )}\) | \(215\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.97, size = 381, normalized size = 3.74 \begin {gather*} \left [\frac {3 \, {\left (a \cos \left (f x + e\right ) - a\right )} \sqrt {-a} \log \left (-\frac {8 \, a \cos \left (f x + e\right )^{3} - 4 \, {\left (2 \, \cos \left (f x + e\right )^{2} - \cos \left (f x + e\right )\right )} \sqrt {-a} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \sin \left (f x + e\right ) - 7 \, a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right ) + 1}\right ) \sin \left (f x + e\right ) + 4 \, {\left (5 \, a \cos \left (f x + e\right )^{2} - 3 \, a \cos \left (f x + e\right )\right )} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}}}{6 \, {\left (c^{2} f \cos \left (f x + e\right ) - c^{2} f\right )} \sin \left (f x + e\right )}, \frac {3 \, {\left (a \cos \left (f x + e\right ) - a\right )} \sqrt {a} \arctan \left (\frac {2 \, \sqrt {a} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right ) \sin \left (f x + e\right )}{2 \, a \cos \left (f x + e\right )^{2} + a \cos \left (f x + e\right ) - a}\right ) \sin \left (f x + e\right ) + 2 \, {\left (5 \, a \cos \left (f x + e\right )^{2} - 3 \, a \cos \left (f x + e\right )\right )} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}}}{3 \, {\left (c^{2} f \cos \left (f x + e\right ) - c^{2} f\right )} \sin \left (f x + e\right )}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \frac {\int \frac {a \sqrt {a \sec {\left (e + f x \right )} + a}}{\sec ^{2}{\left (e + f x \right )} - 2 \sec {\left (e + f x \right )} + 1}\, dx + \int \frac {a \sqrt {a \sec {\left (e + f x \right )} + a} \sec {\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )} - 2 \sec {\left (e + f x \right )} + 1}\, dx}{c^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 318 vs.
\(2 (90) = 180\).
time = 1.28, size = 318, normalized size = 3.12 \begin {gather*} -\frac {\frac {3 \, \sqrt {-a} a^{2} \log \left (\frac {{\left | 2 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} - 4 \, \sqrt {2} {\left | a \right |} - 6 \, a \right |}}{{\left | 2 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} + 4 \, \sqrt {2} {\left | a \right |} - 6 \, a \right |}}\right ) \mathrm {sgn}\left (\cos \left (f x + e\right )\right )}{c^{2} {\left | a \right |}} + \frac {4 \, \sqrt {2} {\left (3 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{4} \sqrt {-a} a^{2} \mathrm {sgn}\left (\cos \left (f x + e\right )\right ) - 3 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} \sqrt {-a} a^{3} \mathrm {sgn}\left (\cos \left (f x + e\right )\right ) + 2 \, \sqrt {-a} a^{4} \mathrm {sgn}\left (\cos \left (f x + e\right )\right )\right )}}{{\left ({\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} - a\right )}^{3} c^{2}}}{3 \, f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\left (a+\frac {a}{\cos \left (e+f\,x\right )}\right )}^{3/2}}{{\left (c-\frac {c}{\cos \left (e+f\,x\right )}\right )}^2} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________